<?php
/* @var $this VideoController */
/* @var $model Video */

$this->breadcrumbs=array(
	'Videos'=>array('index'),
	'Manage',
);

$this->menu=array(
	array('label'=>'Create Video', 'url'=>array('create')),
);

Yii::app()->clientScript->registerScript('search', "
$('.search-button').click(function(){
	$('.search-form').toggle();
	return false;
});
$('.search-form form').submit(function(){
	$('#video-grid').yiiGridView('update', {
		data: $(this).serialize()
	});
	return false;
});
");
?>

<?php //echo CHtml::link('Advanced Search','#',array('class'=>'search-button')); ?>
<div class="search-form" style="display:none">
<?php $this->renderPartial('_search',array(
	'model'=>$model,
)); ?>
</div><!-- search-form -->

<div class="row-fluid">
    <div class="span12 box bordered-box orange-border" style="margin-bottom:0;">
        <div class="box-header blue-background">
            <div class="title">Manage Video</div>
            <div class="actions">
                <a href="#" class="btn box-collapse btn-mini btn-link"><i></i>
                </a>
            </div>
        </div>
        <div class="box-content box-no-padding">
            <div class="responsive-table">
                <div class="scrollable-area">
                    <div id="DataTables_Table_0_wrapper" class="dataTables_wrapper form-inline" role="grid">
                        
						<?php $this->widget('zii.widgets.grid.CGridView', array(
							'id'=>'video-grid',
							'dataProvider'=>$model->search(),
							'filter'=>$model,
							'columns'=>array(
//								'id',
								'name',
//								'description',
//								'content',
								'url',
//								'active',
//								'created_at',
//								'updated_at',
								array(
									'class'=>'CButtonColumn',
								),
							),
						)); 
						?>

                    </div>
                </div>
            </div>
        </div>
    </div>
</div>

